<template>
    <div class="heard">
        <van-nav-bar left-text="自由行.定制" left-arrow :left-text-color="'#ffffff'" @click-left="onClickLeft" />
        <div class="sousuo">
            <span class="address" @click="todizhi">{{ di }}</span>
            <van-icon name="search" />
            <span @click="ToHaving">目的地/主题/景点</span>
        </div>

    </div>
</template>

<script>
export default {
    data() {
        return {
            value: '',
            di: localStorage.getItem("cityName") || "西安",// 当前城市 
        }
    },
    mounted() {
        this.dizhi()
    },
    methods: {
        onClickLeft() {
            // console.log('点击了左侧按钮');
            this.$router.go(-1);
        },
        ToHaving() {
            this.$router.push('/TravelList');
        },
        todizhi() {
            this.$router.push('/DiZhi');
        },


    }
}
</script>

<style scoped lang="scss">
.heard {
    height: 44px;
    line-height: 44px;
    background-color: #00F0F9;
    display: flex;
    justify-content: space-between;

    .van-nav-bar {
        width: 150px;
        background: #00F0F9;

        ::v-deep .van-nav-bar__text {
            color: #ecf0f0 !important;
        }



        ::v-deep .van-nav-bar__arrow {
            color: #ecf0f0 !important;
        }
    }

    .sousuo {
        width: 60%;
        height: 44px;
        background-color: #F5F5F5;
        align-items: center;
        color: #a6abab;
        border-radius: 15px;
        padding-left: 20px;
        margin-top: 5px;

        span {
            font-size: 14px;
        }

        .address {
            color: #000;
        }
    }

}
</style>